home *** CD-ROM | disk | FTP | other *** search
/ Delphi 5 for Professionals / DELPHI5.iso / AddOns / Components / Cell Control / DATA1.CAB / VCDEMO_Files / cell.h < prev    next >
Encoding:
C/C++ Source or Header  |  1998-01-11  |  12.7 KB  |  276 lines

  1. #if !defined(AFX_CELL_H__A614CD07_7E20_11D2_B6B4_444553540000__INCLUDED_)
  2. #define AFX_CELL_H__A614CD07_7E20_11D2_B6B4_444553540000__INCLUDED_
  3.  
  4. #if _MSC_VER >= 1000
  5. #pragma once
  6. #endif // _MSC_VER >= 1000
  7. // Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
  8.  
  9. // NOTE: Do not modify the contents of this file.  If this class is regenerated by
  10. //  Microsoft Visual C++, your modifications will be overwritten.
  11.  
  12. /////////////////////////////////////////////////////////////////////////////
  13. // CCell wrapper class
  14.  
  15. class CCell : public CWnd
  16. {
  17. protected:
  18.     DECLARE_DYNCREATE(CCell)
  19. public:
  20.     CLSID const& GetClsid()
  21.     {
  22.         static CLSID const clsid
  23.             = { 0xdd44c0ea, 0xb2cf, 0x11d1, { 0x8d, 0xd2, 0x44, 0x45, 0x53, 0x54, 0x0, 0x0 } };
  24.         return clsid;
  25.     }
  26.     virtual BOOL Create(LPCTSTR lpszClassName,
  27.         LPCTSTR lpszWindowName, DWORD dwStyle,
  28.         const RECT& rect,
  29.         CWnd* pParentWnd, UINT nID,
  30.         CCreateContext* pContext = NULL)
  31.     { return CreateControl(GetClsid(), lpszWindowName, dwStyle, rect, pParentWnd, nID); }
  32.  
  33.     BOOL Create(LPCTSTR lpszWindowName, DWORD dwStyle,
  34.         const RECT& rect, CWnd* pParentWnd, UINT nID,
  35.         CFile* pPersist = NULL, BOOL bStorage = FALSE,
  36.         BSTR bstrLicKey = NULL)
  37.     { return CreateControl(GetClsid(), lpszWindowName, dwStyle, rect, pParentWnd, nID,
  38.         pPersist, bStorage, bstrLicKey); }
  39.  
  40. // Attributes
  41. public:
  42.     long GetCols();
  43.     void SetCols(long);
  44.     BOOL GetBorder();
  45.     void SetBorder(BOOL);
  46.     BOOL GetTopLabelVisible();
  47.     void SetTopLabelVisible(BOOL);
  48.     BOOL GetSideLabelVisible();
  49.     void SetSideLabelVisible(BOOL);
  50.     BOOL GetHScrollVisible();
  51.     void SetHScrollVisible(BOOL);
  52.     BOOL GetVScrollVisible();
  53.     void SetVScrollVisible(BOOL);
  54.     BOOL GetPageLabelVisible();
  55.     void SetPageLabelVisible(BOOL);
  56.     long GetTopLabelHeight();
  57.     void SetTopLabelHeight(long);
  58.     long GetSideLabelWidth();
  59.     void SetSideLabelWidth(long);
  60.     BOOL GetRowSelectedMode();
  61.     void SetRowSelectedMode(BOOL);
  62.     BOOL GetMultiSelectedMode();
  63.     void SetMultiSelectedMode(BOOL);
  64.     BOOL GetDynamicEditArea();
  65.     void SetDynamicEditArea(BOOL);
  66.     BOOL GetMultiColSizeMode();
  67.     void SetMultiColSizeMode(BOOL);
  68.     BOOL GetMultiRowSizeMode();
  69.     void SetMultiRowSizeMode(BOOL);
  70.     BOOL GetEnablePopMenu();
  71.     void SetEnablePopMenu(BOOL);
  72.     BOOL GetCurrentTopLabelHint();
  73.     void SetCurrentTopLabelHint(BOOL);
  74.     BOOL GetCurrentSideLabelHint();
  75.     void SetCurrentSideLabelHint(BOOL);
  76.     BOOL GetResizeWhenPasteNeed();
  77.     void SetResizeWhenPasteNeed(BOOL);
  78.     BOOL GetAllowSizeCell();
  79.     void SetAllowSizeCell(BOOL);
  80.     BOOL GetGridReadOnly();
  81.     void SetGridReadOnly(BOOL);
  82.     long GetRows();
  83.     void SetRows(long);
  84.     BOOL GetEnableUndo();
  85.     void SetEnableUndo(BOOL);
  86.     BOOL GetAllowSizeRowInGrid();
  87.     void SetAllowSizeRowInGrid(BOOL);
  88.     BOOL GetAllowSizeColInGrid();
  89.     void SetAllowSizeColInGrid(BOOL);
  90.  
  91. // Operations
  92. public:
  93.     void DoPrint(BOOL showdlg);
  94.     void DoPrintPageSetup();
  95.     void DoSetCellAlignment(long col, long row, long align);
  96.     void DoSetCellTextStyle(long col, long row, long style);
  97.     void DoSetCell3DState(long col, long row, long state);
  98.     void DoSetCellData(long col, long row, const VARIANT& data);
  99.     void DoSetCellNumberStyle(long col, long row, BOOL commas, BOOL percent, short decimal, short currencychar, double unit, short minus, BOOL mathstyle);
  100.     void DoSetButtonCell(long col, long row, LPCTSTR text, LPCTSTR mesg);
  101.     void DoSetRadioCell(long col, long row, LPCTSTR items);
  102.     void DoSetDroplistCell(long col, long row, LPCTSTR items, BOOL hidetag, BOOL readonly);
  103.     void DoSetCheckboxCell(long col, long row, LPCTSTR text);
  104.     void DoSetTextSpinCell(long col, long row, LPCTSTR items);
  105.     void DoSetValueSpinCell(long col, long row, double min, double max, double step);
  106.     void DoSetNormalCell(long col, long row);
  107.     void DoSetCellInputControlCase(long col, long row, short state);
  108.     void DoSetCellInputControlMask(long col, long row, LPCTSTR mask);
  109.     void DoSetCellInputOnlyValue(long col, long row, BOOL maxflag, double max, BOOL minflag, double min);
  110.     void DoSetCellColor(long col, long row, long foreclr, long backclr);
  111.     void DoInsertCol(long col, long count);
  112.     void DoInsertRow(long row, long count);
  113.     void DoAppendCol(long count);
  114.     void DoAppendRow(long count);
  115.     void DoRedrawAll();
  116.     void DoRedrawCell(long col, long row);
  117.     void DoRedrawRange(long startcol, long startrow, long endcol, long endrow);
  118.     void DoRedrawGrid();
  119.     void DoRedrawTopLabel();
  120.     void DoRedrawSideLabel();
  121.     void DoRedrawHScroll();
  122.     void DoRedrawVScroll();
  123.     void DoRedrawPageLabel();
  124.     void DoDeletePage(long index, long count);
  125.     void DoSetPageLabel(long index, LPCTSTR label);
  126.     void DoDeleteCol(long pos, long count);
  127.     void DoDeleteRow(long pos, long count);
  128.     void DoAppendPage(LPCTSTR label, long count);
  129.     void DoSetCellFont(long col, long row, long size, long style, LPCTSTR name);
  130.     long DoGetLeftCol();
  131.     long DoGetTopRow();
  132.     long DoGetCurrentCol();
  133.     long DoGetCurrentRow();
  134.     void DoSetDefaultRowHeight(long height);
  135.     void DoSetDefaultColWidth(long width);
  136.     void DoSetRowHeight(long row, long height);
  137.     void DoSetColWidth(long col, long width);
  138.     BOOL DoGetColWidth(long col, long* width);
  139.     BOOL DoGetRowHeight(long row, long* height);
  140.     void DoSortByCol(BOOL direction, long col);
  141.     void DoSetSortCol(long col, BOOL sort);
  142.     void DoJoinCells(long startcol, long startrow, long endcol, long endrow);
  143.     void DoUnJoinCells(long col, long row);
  144.     void DoSetLeftCol(long col);
  145.     void DoSetTopRow(long row);
  146.     void DoMoveToCell(long col, long row);
  147.     BOOL DoGetJoinRange(long col, long row, long* startcol, long* startrow, long* endcol, long* endrow);
  148.     void DoSetFormula(long col, long row, LPCTSTR text);
  149.     void DoDelFormula(long col, long row);
  150.     void DoCalculateAll();
  151.     BOOL IsFormulaCell(long col, long row);
  152.     void DoSetRefChart(long col, long row, long startcol, long startrow, long endcol, long endrow);
  153.     void DoSetChart(long col, long row, long datacols, long datarows);
  154.     void DoSetChartRefData(long col, long row, long chartdatacol, long chartdatarow, long refcol, long refrow);
  155.     void DoSetChartData(long col, long row, long chartdatacol, long chartdatarow, const VARIANT& data);
  156.     void DoDelChart(long col, long row);
  157.     BOOL IsChartCell(long col, long row);
  158.     void DoSetDefaultFont(long size, long style, LPCTSTR name);
  159.     void DoSelectCell(long col, long row);
  160.     void DoSelectRange(long startcol, long startrow, long endcol, long endrow);
  161.     void DoClearSelection();
  162.     BOOL IsSelectedCell(long col, long row);
  163.     void DoCopyArea(long startcol, long startrow, long endcol, long endrow);
  164.     void DoCopySelected();
  165.     void DoCutSelected();
  166.     void DoCutArea(long startcol, long startrow, long endcol, long endrow);
  167.     void DoPaste(long col, long row, BOOL samesize);
  168.     BOOL DoGetFirstSelectedCell(long* col, long* row);
  169.     BOOL DoGetNextSelectedCell(long* col, long* row);
  170.     BOOL DoGetCellData(long col, long row, VARIANT* data);
  171.     void DoDrawHLine(long col1, long col2, long row, BOOL top, long color, long size);
  172.     void DoDrawVLine(long row1, long row2, long col, BOOL left, long color, long size);
  173.     void DoDrawXLine(long col1, long row, long col2, long row2, BOOL dir, long color, long size);
  174.     void DoDelXLine(long col1, long row1, long col2, long row2);
  175.     void DoDelUserFunction(LPCTSTR name);
  176.     void DoDelHLine(long col1, long col2, long row, BOOL top);
  177.     void DoDelVLine(long row1, long row2, long col, BOOL left);
  178.     void DoSetCurrentPage(long pageno);
  179.     long DoGetCurrentPage();
  180.     void DoSetTotalPages(long pages);
  181.     long DoGetTotalPages();
  182.     void DoSetCanDragDrop(BOOL drag);
  183.     void DoInsertPage(LPCTSTR label, long location, long count);
  184.     void DoShowCurrentCell(BOOL focus, BOOL highlight);
  185.     void DoSetEqualRowHeight(BOOL equal);
  186.     void DoChartGuide(long col, long row, long col2, long row2);
  187.     void DoInputFormula(long col, long row);
  188.     BOOL DoFetchFuncParameter(short no, VARIANT* para);
  189.     void DoLogin(long id, LPCTSTR passwd);
  190.     BOOL DoCalculateExpr(LPCTSTR expr, short* rettype, VARIANT* exprresult);
  191.     void DoSetCellValue(long col, long row, double value);
  192.     void DoSetCellString(long col, long row, LPCTSTR string);
  193.     void DoSetChartGeneralData(long col, long row, short charttype, BOOL xaxisAttr, LPCTSTR title, LPCTSTR foot, LPCTSTR yaxisTitle);
  194.     void DoRefreshChart(long col, long row);
  195.     BOOL DoGetFormula(long col, long row, VARIANT* text);
  196.     void DoDrawLineDlg();
  197.     void DoDrawLine(long startcol, long startrow, long endcol, long endrow, long type, long size, long color);
  198.     void DoSetChartValueData(long col, long row, long chartcol, long chartrow, double value);
  199.     void DoClearLine(long startcol, long startrow, long endcol, long endrow, long type);
  200.     void DoSetBackGroundDlg();
  201.     void DoSetBackGround(long style);
  202.     void DoSetChartStringData(long col, long row, long chartcol, long chartrow, LPCTSTR text);
  203.     BOOL DoGetColWidthVB(long col, VARIANT* width);
  204.     BOOL DoGetRowHeightVB(long row, VARIANT* height);
  205.     BOOL DoGetJoinRangeVB(long col, long row, VARIANT* startcol, VARIANT* startrow, VARIANT* endcol, VARIANT* endrow);
  206.     BOOL DoCalculateExprVB(LPCTSTR expr, VARIANT* rttype, VARIANT* exprsult);
  207.     BOOL DoGetFirstSelectedCellVB(VARIANT* col, VARIANT* row);
  208.     void DoFind(BOOL withrepl);
  209.     void DoReplace();
  210.     void DoLocate();
  211.     void DoShowFindDialog(BOOL show);
  212.     void DoCloseFindDialog();
  213.     BOOL DoGetNextSelectedCellVB(VARIANT* col, VARIANT* row);
  214.     void DoSetDropGridCell(long col, long row, long areacol1, long arearow1, long areacol2, long arearow2, long pageno, BOOL onlycol, long validcol, BOOL hidetag, BOOL readonly);
  215.     BOOL DoOpenFileDbase(short dbasetype, LPCTSTR filename, VARIANT* tables);
  216.     BOOL DoOpenODBCDbase(LPCTSTR connectstr, VARIANT* tables);
  217.     void DoCloseDbase();
  218.     void DoPrintPreview(BOOL allowPageset);
  219.     void DoSetPrintHead(LPCTSTR left, LPCTSTR mid, LPCTSTR right);
  220.     void DoSetPrintFoot(LPCTSTR left, LPCTSTR mid, LPCTSTR right);
  221.     void DoSetPrintLabel(BOOL collabel, BOOL rowlabel);
  222.     void DoSetPrintTitle(long col1, long row1, long col2, long row2, long Rows, long Cols);
  223.     void DoSetCellPicture(long col, long row, LPCTSTR picturefile, long style);
  224.     void DoSetButtonCellEx(long col, long row, LPCTSTR text, LPCTSTR runstring);
  225.     void DoCalculatePage(long pageno);
  226.     void DoUndo();
  227.     void DoRedo();
  228.     void DoDiscardUndo();
  229.     BOOL DoGetRedoState();
  230.     BOOL DoGetUndoState();
  231.     void DoSetMessageTitle(const VARIANT& title);
  232.     void DoSetPageCellData(long col, long row, long page, const VARIANT& data);
  233.     BOOL DoGetPageCellData(long col, long row, long page, VARIANT* data);
  234.     void DoSetCellReadOnly(long col, long row, BOOL readonly);
  235.     long DoOpenFile(LPCTSTR filename);
  236.     long DoSaveFile(LPCTSTR filename);
  237.     long DoGetColBestWidth(long col);
  238.     long DoGetRowBestHeight(long row);
  239.     BOOL DoDumpDbaseData(LPCTSTR sqlstring, long col, long row, long page, BOOL withfieldname, VARIANT* dumpcols, VARIANT* dumprows);
  240.     BOOL DoDumpDbaseTable(LPCTSTR tablename, long col, long row, long page, BOOL withfieldname, VARIANT* dumpcols, VARIANT* dumprows);
  241.     BOOL DoAddUserFunction(LPCTSTR functype, LPCTSTR funcname, short rttype, short paranum, short* paratype, LPCTSTR funchelp);
  242.     BOOL DoAddUserFunctionVB(LPCTSTR functype, LPCTSTR funcname, long rttype, long paranum, LPCTSTR paratype, LPCTSTR funchelp);
  243.     void DoSetPrintPara(float scale, short papersize, BOOL orientation);
  244.     BOOL DoOpenFileDbaseVfp(short dbasetype, LPCTSTR filename);
  245.     BOOL DoDumpDbaseDataVfp(LPCTSTR sqlstring, long col, long row, long page, BOOL withfieldname);
  246.     BOOL DoCreateODBCDSN(LPCTSTR drivername, LPCTSTR description);
  247.     BOOL DoRemoveODBCDSN(LPCTSTR dsnname);
  248.     BOOL DoOpenODBCDbaseVfp(LPCTSTR connectstr);
  249.     void DoSetColWidthEx(long col1, long col2, double width, short units);
  250.     void DoSetRowHeightEx(long row1, long row2, double height, short units);
  251.     void DoSetUnScrollRow(long row1, long row2);
  252.     void DoSetUnScrollCol(long col1, long col2);
  253.     BOOL DoGetSelectRange(VARIANT* col1, VARIANT* row1, VARIANT* col2, VARIANT* row2);
  254.     void DoResetContent();
  255.     void DoSetPrinter(LPCTSTR devname);
  256.     void DoSetPrintPara2(short scale, BOOL gridline, BOOL allcell);
  257.     void DoSetCellPrintable(long col, long row, BOOL hide);
  258.     BOOL DoAppendPageFromFile(LPCTSTR filename, long startpage, long count);
  259.     BOOL IsModified();
  260.     void DoSetModifiedFlag(BOOL modified);
  261.     BOOL DoCopyPage(long dest, long source);
  262.     void DoPrintPage(long page, BOOL showdlg);
  263.     void DoPrintPreviewPage(long page, BOOL allowPageset);
  264.     void DoSetHintButtonCell(long col, long row, LPCTSTR text, LPCTSTR mesg, BOOL hide, BOOL canEdit);
  265.     long DoSaveTextFile(LPCTSTR filename, long format);
  266.     long DoSaveHtmlFile(LPCTSTR filename);
  267.     long DoReadTextFile(LPCTSTR filename, long format);
  268.     BOOL DoAddUserFunctionEx(LPCTSTR functype, LPCTSTR name, short rttype, short paranum, short* paratype, short* defaultpara, LPCTSTR funchelpstring);
  269.     void AboutBox();
  270. };
  271.  
  272. //{{AFX_INSERT_LOCATION}}
  273. // Microsoft Developer Studio will insert additional declarations immediately before the previous line.
  274.  
  275. #endif // !defined(AFX_CELL_H__A614CD07_7E20_11D2_B6B4_444553540000__INCLUDED_)
  276.